<?php

/**
 *时间轴事件发布
 */
$sql = "
CREATE TABLE IF NOT EXISTS " . tablename('micro_test') . " (
`id` int(10) unsigned  AUTO_INCREMENT,
`question` varchar(200) NOT NULL,
`ans_a` varchar(100),
`ans_b` varchar(100),
`ans_c` varchar(100),
`ans_d` varchar(100),
`correct_ans` varchar(10) NOT NULL,
 PRIMARY KEY (`id`)
) ENGINE=MyISAM  DEFAULT CHARSET=utf8;";
pdo_query($sql);

$sql = "
CREATE TABLE IF NOT EXISTS " . tablename('micro_testsetting') . " (
`id` int(10) unsigned  AUTO_INCREMENT,
`title` varchar(40) NOT NULL,
`copyright` varchar(100),
`share_title` varchar(100),
`share_icon` varchar(200),
`share_content` varchar(200),
 PRIMARY KEY (`id`)
) ENGINE=MyISAM  DEFAULT CHARSET=utf8;";
pdo_query($sql);


$sql = "
CREATE TABLE IF NOT EXISTS " . tablename('micro_test_user') . " (
 `id` int(10) unsigned  AUTO_INCREMENT,
 `openid` varchar(200) NOT NULL,
 `nickname` varchar(100) NOT NULL,
 `phone` varchar(20),
 `company` varchar(100),
 `headimgurl` varchar(200) NOT NULL,
 `score` int(10),
 PRIMARY KEY (`id`)
) ENGINE=MyISAM  DEFAULT CHARSET=utf8;";
pdo_query($sql);





